//
//  UPTextField.h
//  Uang Pasti
//
//  Created by 李永彬 on 2025/8/17.
//

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN

@interface UPTextField : UIView

@property (nonatomic, strong, readonly) UILabel *prefixLabel;
@property (nonatomic, strong, readonly) UITextField *textField;

- (instancetype)initWithFrame:(CGRect)frame NS_DESIGNATED_INITIALIZER;
- (instancetype)initWithCoder:(NSCoder *)coder NS_UNAVAILABLE;

- (void)configureWithPrefix:(NSString *_Nullable)prefix
              prefixHidden:(BOOL)hidden
                maxLength:(NSInteger)maxLength
               placeholder:(NSString *)placeholder
              keyboardType:(UIKeyboardType)keyboardType;

- (void)updatePrefix: (NSString *_Nullable)prefix;

@end

NS_ASSUME_NONNULL_END
